package com.cn.jiyun;


import com.cn.jiyun.entity.pojo.Order;
import com.jiyun.entity.vo.OrderVo;
import com.jiyun.result.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(value = "order-service")
public interface OrderClient {
    @RequestMapping("/order/findAll")
    public Result<List<Order>> findAll();
    @RequestMapping("/order/findById")
    public Result<Order> findById(@RequestParam Integer id);
    @PostMapping("/order/addOrder")
    public Result<Boolean> addOrder(@RequestBody OrderVo orderVo);
}
